<!--
 * @Description:: 请补充填写
 * @Version: 1.0
 * @Author: 小白
 * @Date: 2022-04-14 14:32:34
 * @LastEditors: 小白
 * @LastEditTime: 2025-10-22 17:10:59
 * @FilePath: \tmsadmin\src\views\contract\staff\components\searchDetails.vue
-->
<template>
  <el-card class="search_card" shadow="never">
    <template #header>
      <div class="card-header">
        <span>条件筛选</span>
      </div>
    </template>
    <el-form :model="form" label-width="100px">
      <el-row>
        <el-col :lg="6" :md="8">
          <el-form-item label="姓名">
            <el-input
              style="width: 100%"
              v-model="form.staff"
              placeholder="请输入"
            />
          </el-form-item>
        </el-col>
        <el-col :lg="6" :md="8">
          <el-form-item label="合同编号">
            <el-input
              style="width: 100%"
              v-model="form.contractNo"
              placeholder="请输入"
            />
          </el-form-item>
        </el-col>
        <el-col :lg="6" :md="8">
          <el-form-item label="签署状态">
            <!-- 签署状态 -->
             <el-select v-model="form.status" placeholder="请选择">
              <el-option v-for="item in statusList" :key="item.value" :label="item.label" :value="item.value"></el-option>
             </el-select>
          </el-form-item>
        </el-col>
        
        <el-col :lg="6" :md="24" style="text-align: right">
          <el-button type="primary" @click="searchFun"> 搜索 </el-button>
          <el-button @click="restFun"> 重置 </el-button>
        </el-col>
      </el-row>
    </el-form>
  </el-card>
</template>
<script lang="ts" setup>
import { ref } from 'vue'
const emits = defineEmits(['search'])
const form = ref({
   staff: '',
  contractNo:'',
  status:'',
})
const statusList = ref([
  {
    label: '未签署',
    value: 1,
  },
  {
    label: '已签署',
    value: 2,
  }
])
const props = defineProps({
  houseList: {
    type: Array,
    default: () => [],
  }
})
const searchFun = () => {
  emits('search', form.value)
}
const restFun = () => {
  form.value = {
    staff: '',
    status:'',
contractNo:'',
  }
  emits('search', form.value)
}
</script>

<style lang="scss" scoped>
// @import '@/style/variables.scss';
.card-header {
  display: flex;
  justify-content: space-between;
  .more_text {
    cursor: pointer;
    color: $color;
  }
}
</style>
